package com.itheima.sh.c;

public class RandomNumHandlerDemo {
    public static void main(String[] args) {
        /*useRandomNumHandler(new RandomNumHandler() {
            @Override
            public int getNumber() {
                return 0;
            }
        });*/

        //简化
        useRandomNumHandler(() ->  0);
    }
    public static void useRandomNumHandler(RandomNumHandler rh){
        rh.getNumber();
    }
}
